/**
 * 
 */
package com.study.adapter;

/**
 * @author Administrator
 * @date 2019年6月23日
 */
public class App {

	public static void main(String[] args) {
		/*
		 v1: 系统只是实现了将日志写入到文件里
		 v2: 通过适配器实现将日志写到DB中
		 */
		LogBean logBean = new LogBean();
		logBean.setLogId("001");
		logBean.setLogText("这是001日志");
		LogWriteFileService logWriteFileService = new LogWriteFileServiceImpl(logBean);
		//logWriteFileService.writeFile();
		LogAdapter logAdapter = new LogAdapter(logWriteFileService);
		logAdapter.writeLog();
	}
}
